import React from 'react'
import { Button } from 'antd';
import axios from '../../../utils/axios'
import '../../../assets/css/Car/Delbtn.css'

const Del=(props)=> {
  const Delbtn=()=>{
    console.log(props.msg);
    axios({
      url: "/car/carPage/deleteCar",
      method: "get",
      params: {
        car_number:props.msg,
      }
    }).then((res) => {
      console.log(res);
    }).then((err) => {
      console.log(err);
    })
  }
  
  return (
    <div>
      <Button type="primary" danger onClick={Delbtn} className='Delbtn'>
      删除
    </Button>
    </div>
  )
}
export default Del